home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 December / Chip_2001-12_cd1.bin / zkuste / tuning / download / xteq / setup.exe / {app} / plugins / XQ Startmenu Special Folders 2.xpl < prev    next >
Text File  |  2000-09-02  |  2KB  |  72 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="6"
  3. "COUNT"="2"
  4. "UIPATH"="Appearance\Start menu\Cascaded Items"
  5. "NAME"="Special Folders #2"
  6. "VERSION"="1.10"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="Show cascading "History" in Start menu"
  9. "TEXT 2"="Show cascading "Subscriptions" in Start menu"
  10. "DESCRIPTION 1"="Use this plug-in to show some of the "special" folder of Window in cascading menu so you can easily access them."
  11. "AUTHOR"="Xteq Systems"
  12. "CONTACTURL"="http://www.xteq.com"
  13. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  14. "COMMENT 1"=" "
  15.  
  16.  
  17. 'Declaration of some constants
  18. sP="HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\Start Menu"
  19. sPath=""
  20.  
  21.       sV1="History.{FF393560-C2A7-11CF-BFF4-444553540000}"
  22. sV2="Subscriptions.{F5175861-2688-11D0-9C5E-00AA00A45957}"
  23.  
  24. 'Called when the Plugin is started
  25. SUB Plugin_Initialize 
  26.  sPath=RegReadValue(sP)
  27.  if FolderExists(sPath) then
  28.     if right(sPath,1)<>"\" then sPath=sPath & "\"
  29.  
  30.  
  31.     if FolderExists(sPath & sV1) then SetUIElement 1,true
  32.     if FolderExists(sPath & sV2) then SetUIElement 2,true
  33.  else
  34.     Disable
  35.  end if
  36. END SUB
  37.  
  38. 'Called when the Plugin should validate the Data the user has entered
  39. SUB Plugin_CheckData(ElementIndex)
  40. END SUB
  41.  
  42. 'Called when the Plugin should apply the changes
  43. SUB Plugin_Apply(ElementIndex,ElementSubIndex) 
  44.  b=GetUIElement(1)
  45.  if b=true then
  46.     if FolderExists(sPath & sV1)=false then     
  47.        Call FolderCreate(sPath & sV1)
  48.     end if
  49.  else
  50.     if FolderExists(sPath & sV1)=true then
  51.        FolderDelete(sPath & sV1)
  52.     end if
  53.  end if
  54.  
  55.  b=GetUIElement(2)
  56.  if b=true then
  57.     if FolderExists(sPath & sV2)=false then
  58.        Call FolderCreate(sPath & sV2)
  59.     end if
  60.  else
  61.     if FolderExists(sPath & sV2)=true then
  62.        FolderDelete(sPath & sV2)
  63.     end if
  64.  end if
  65.  
  66. END SUB
  67.  
  68.  
  69. 'Called when the Plugin is about to be removed from memory
  70. SUB Plugin_Terminate
  71. END SUB
  72.